<template>
  <van-swipe class="my-swipe" :autoplay="30000" indicator-color="white">
    <van-swipe-item v-for="item of data" :key="item.id">
      <img :src="item.src" alt="" />
    </van-swipe-item>
  </van-swipe>
</template>

<script lang="ts">
import { defineComponent } from "vue";

export default defineComponent({
  props: ["data"],
  setup() {
    return {};
  },
});
</script>

<style lang='scss' scoped>
.my-swipe .van-swipe-item {
  color: #fff;
  font-size: 20px;
  line-height: 150px;
  text-align: center;
  background-color: #39a9ed;
  height: 180px;
  img{
    width: 100%;
    height: 100%;
  }
}
</style>
